import React from 'react';
interface PersonProps {
    name: string
    content?: React.ReactNode
}
function Person(props: PersonProps) {//
    return (
        <div>
            <h3>你好我是{props.name}</h3>
            {props.content}
        </div>
    )
}
const Animal: React.FunctionComponent<PersonProps> = (props) => {
    return (
        <div>我是一个{props.name}</div>
    )
}
function App() {
    return (
        <div>
            <div>react-ts</div>
            <Person name="张三" content={<button>按钮</button>} />
            <Animal name='狗' />
        </div>
    )
}
export default App;